﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.IO;

namespace TradeTestWeb
{
    /// <summary>
    /// IJQMZWebS 的摘要说明
    /// </summary>
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [System.ComponentModel.ToolboxItem(false)]
    // 若要允许使用 ASP.NET AJAX 从脚本中调用此 Web 服务，请取消对下行的注释。
    // [System.Web.Script.Services.ScriptService]
    public class IJQMZWebSservice : System.Web.Services.WebService
    {
        [WebMethod]
        public int SearchPeop(string sHospitalCode, string sRYType, string sMZJCode, string sObligate1, string sObligate2, string sObligate3, string sObligate4, string sObligate5, ref string sResult, ref string sMessage)
        {
            sResult = File.ReadAllText(Server.MapPath("~") + "\\SearchPeop.xml");
            return 1;
        }

        [WebMethod]
        public int ZY_BRDJ(
                    string sHospitalCode,
                    string sMZJCode,
                    string sPeopCode,
                    string sRYType,
                    string sXM,
                    string sSFZH,
                    string sKH,
                    string sZYKS,
                    string sZYCode,
                    string sCH,
                    string sRYZDCode,
                    string sRYZDName,
                    string sRYZT,
                    string sRYSJ,
                    string sRYDJR,
                    string sLXDH,
                    string sObligate1,
                    string sObligate2,
                    string sObligate3,
                    string sObligate4,
                    string sObligate5,
                    ref string sAreaCode,
                    ref string sJZKey,
                    ref string sMZBH,
                    ref string sMessage)
        {
            sAreaCode = "330110";
            sJZKey = "K" + sZYCode;
            sMZBH = sCH;
            sMessage = "";
            return 1;
        }

        [WebMethod]
        public int QXDJ(string sHospitalCode, string sJZKey, string sQXR, string sObligate1, string sObligate2, string sObligate3, string sObligate4, string sObligate5, ref string sMessage)
        {
            return 1;
        }

        [WebMethod]
        public int UPMXPL(string sHospitalCode, string sJZKey, string sInput, string sObligate1, string sObligate2, string sObligate3, string sObligate4, string sObligate5, ref string sResult, ref string sMessage)
        {
            sResult = File.ReadAllText(Server.MapPath("~") + "\\UPMXPL.xml");
            sMessage = "测试上传";
            return 1;
        }

        [WebMethod]
        public int ZY_BRJS(
                    string sJSType,
                    string sHospitalCode,
                    string sJZKey,
                    string sCYSJ,
                    string sCYZDCode,
                    string sCYZDName,
                    string sCYZT,
                    string sCYYY,
                    string sJSSJ,
                    string sJSR,
                    string sJZZJE,
                    string sQFJE,
                    string sKBXZJE,
                    string sZFJE,
                    string sZiFJE,
                    string sJMJE,
                    string sBXJE,
                    string sDJH,
                    string sObligate1,
                    string sObligate2,
                    string sObligate3,
                    string sObligate4,
                    string sObligate5,
                    ref string sResult,
                    ref string sMessage)
        {
            sResult = File.ReadAllText(Server.MapPath("~") + "\\ZY_BRJS.xml");
            sMessage = "成功";
            return 1;
        }

        [WebMethod]
        public int QXJS(string s0, string s1, string s2, string s3, string s4, string s5, string s6, string s7, string s8, ref string s9, ref string s10)
        {
            s9 = DateTime.Now.ToString();
            return 1;
        }

        [WebMethod]
        public int UPPLQX(string sHospitalCode, string sJZKey, string sObligate1, string sObligate2, string sObligate3, string sObligate4, string sObligate5, ref string sMessage)
        {
            sMessage = "测试上传";
            return 1;
        }
    }
}
